﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Main.master" AutoEventWireup="true" CodeFile="SearchUser.aspx.cs" Inherits="SearchBug" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CustomJavascript" runat="Server">

    <link href="/css/agent_admin.css" rel="stylesheet" type="text/css" />
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="FlashMessage" runat="Server">
    Enter your keywords below to start searching
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="Server">
    <div id="tabs-search" class="ui-tabs-panel ui-widget-content ui-corner-bottom">
        <div id="agent_search_tab" class="cols_no_height interaction_panel whole_width_interaction" style="background: #fff;">
            <div id="search_toolbar" class="search_toolbar">
                <div class="search_toolbar_inside" style="margin-top: -7px; margin-left: 5px;">
                    <div class="row_name">
                        Search
                    </div>
                    <div class="row_desc">
                        Search across users, projects, and bugs information
                    </div>
                </div>
            </div>
            <div id="agent_search_main_part">
                <div class="agent_search_main_part_inside">
                    <div class="agent_search_main_part_inside_center">
                        <asp:TextBox  class="default xl hint_text" ID="searchtxt" MaxLength="100" name="txtsearch" Text="" size="100" Style="width: 400px; padding: 6px ; " runat="server" ></asp:TextBox>
                        <div style="display: inline-block; zoom: 1; *display: inline; position: relative; top: 10px; left: 5px">
                            <asp:RadioButton Checked="true" ID="rdUser" Style="margin-right: 3px;" value="100" GroupName="SearchName" AutoPostBack="True"  runat="server" />User<br />
                            <asp:RadioButton  ID="rdBug" Style="margin-right: 3px;" value="200"
                                GroupName="SearchName" runat="server" oncheckedchanged="rdBug_CheckedChanged" />Bug
                        </div>
                        <span class="input button" style="margin-left: 10px;">
                            <asp:Button class="blue_highlight search_detailed" runat="server"
                            Text="Search" ID="btnSearch" onclick="btnSearch_Click" />
                            <span class="icon">&nbsp; </span><span class="text "></span>
                        </span>
                        <div style="margin-top: 5px;">
                            <asp:LinkButton ID="lbtnAdvancedSearch" runat="server" Text="Advanced Search"
                                onclick="lbtnAdvancedSearch_Click">
                            </asp:LinkButton>
                        </div>
                        <!-- begin here -->
                        <div class="<asp:Literal ID="ltrSearchAdvanced" runat="server"></asp:Literal>">
                             <div class="a-field">
                                <label>Project Name</label>
                                <div class="a-select">
                                    <asp:DropDownList runat="server" ID="ddlProjectName">
                                    </asp:DropDownList>
                              </div>
                                <div class="a-field">
                                    <label>Bug ID</label>
                                    <div class="a-select">
                                        <asp:DropDownList runat="server" ID="ddlBugID">
                                        </asp:DropDownList>
                                    </div>
                                </div>
                                <!--Creating dropdown list to choose severity-->
                                <div class="a-field">
                                    <label>Role</label>
                                    <div class="a-select">
                                        <asp:DropDownList runat="server" ID="ddlRole">
                                        </asp:DropDownList>
                                    </div>
                                </div>
                                <!--Creating dropdown list to choose priority-->
                                <div class="a-field">
                                    <label>Active</label>
                                    <div class="a-select">
                                        <asp:DropDownList runat="server" ID="ddlActive">
                                            <asp:ListItem Value="0">Active</asp:ListItem>
                                            <asp:ListItem Value="1">Not Active</asp:ListItem>
                                        </asp:DropDownList>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <!-- End here -->
                        <div class="agent_search_main_saved_search_header">
                            <img alt="Search_saved" class="agent_icon_button" src="images/search_saved.png" height="16" width="16" />
                            Result(s) below
                        </div>
                    </div>
                      <div  id="viewimg-user-admin-page" class="a-fields">
      <asp:ListView ID="LVDisplay" runat="server" >
          <EmptyDataTemplate>
              <table id="Table1" runat="server" style="">
                  <tr>
                      <td>
                          No user Found !!!</td>
                  </tr>
              </table>
          </EmptyDataTemplate>
           <LayoutTemplate>
               <div id="ticket_filter_list_header" class="ticket_filter_list_header">
                    <span class="listview_User_Username " >User</span>
                    <span class="listview_User_Fullname ">FullName </span>
                    <span class="listview_User_Role ">Role </span>
                    <span class="listview_User_Email ">Email </span>
                    <span class="listview_User_Organization ">Organization </span>
                    <span class="listview_User_image scrollbar_mover">Image </span>
                    <span class="listview_User_Active ">Active </span>
                    <span class="listview_User_Action ">Actions </span>
                </div>
               <div id="ticket_filter_list_items_outer_div" class="ticket_filter_list_items table_view">
                    <div id="ticket_filter_list_items_data_div">
                        <div id="ticket_filter_list_items">
                            <asp:PlaceHolder ID="itemPlaceholder" runat="server" />
                        </div>
                        <div id="ticket_filter_item_paginator">
                            Page
                            <asp:DataPager ID="DataPager" PageSize="10" runat="server">
                                <Fields>
                                    <asp:NumericPagerField ButtonCount="10" PreviousPageText="«" NextPageText="»" />
                                </Fields>
                            </asp:DataPager>
                        </div>
                    </div>
                </div>
            </LayoutTemplate>
            <ItemTemplate>
                <!-- first item, selected -->
                <div class="ticket_filter_item ticket_filter_item_table_view">
                    <!-- User Name -->
                    <span class="listview_User_Username lesser_data"> <a href="/Bug.aspx?id=<%# Eval("Username") %>"><%# Eval("Username")%></a></span>
                    <!-- Full Name -->
                    <span class="listview_User_Fullname lesser_data"><%# Eval("Fullname")%></span>
                    <!-- Role -->
                    <span class="lesser_data listview_User_Role lesser_data" style="margin-top: 1px"><span class="ticket_filter_item_status_box user_Role_<%# EnumUtility.GetEnumNiceName((UserManagement.ShortRole)Eval("Role"))%>"><span class="ticket_filter_item_data">
                        <%# EnumUtility.GetEnumNiceName((UserManagement.Role)Eval("Role")) %>
                    </span></span></span><!-- Email -->
                    <div class="listview_User_Email lesser_data"><%# Eval("Email")%></div>
                    <!-- Organization -->
                    <div class="listview_User_Organization lesser_data"><%# Eval("Organization")%></div>
                   <!-- AvatarImage -->
                    <span class="ticket_filter_item_tv_type">
                        <img alt=""  class="agent_icon_button vtip" src="/images/user/AvataImage/<%# Eval("AvatarImage") %>.png" />
                    </span><!-- Email -->
                    <div class="listview_User_Active lesser_data "><%# ((Eval("IsActive").ToString()=="True")?"Active":"Not Actice") %></div>
                    <!-- actions -->
                    <span class="listview_User_Action" style="margin-top: 2px;"><a title="Open In New Window" class="ticket_filter_item_tv_tip_open ticket_filter_action_open" href="/Bug.aspx?id=<%# Eval("Username") %>" target="_blank">
                        <img alt="" class="agent_icon_button bug-lightbox" src="/images/open.png" height="16" width="16" /></a> <a title="Quick View" class="ticket_filter_item_tv_tip_view" href="/BugLite.aspx?id=<%# Eval("Username") %>">
                            <img alt="" class="agent_icon_button" src="/images/view.png" height="16" width="16" /></a> <a title="Resolve" class="ticket_filter_item_tv_tip_resolve" href="/BugCheck.aspx?id=<%# Eval("Username") %>">
                                <img alt="" class="agent_icon_button" src="/images/quick_resolve.png" height="16" width="16" /></a> </span>
                </div>
            </ItemTemplate>
        </asp:ListView>

    </div>
                </div>
            </div>
            <div id="search_manage_menu" class="cols_no_height interaction_panel right_col_no_top" style="display: none;">
                <div id="search_manage_menu_inside">
                </div>
            </div>
            <div class="faded_tab">
                <div class="faded_div">
                </div>
                <div id="search_faded_text_tab" class="faded_text_tab" style="background: #fff;">
                </div>
            </div>
            </label>

</asp:Content>